package com.pony.service.impl;

import com.pony.dao.UserMapper;
import com.pony.entity.User;
import com.pony.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service("userService")
public class UserServiceImpl implements UserService {

    @Autowired
    private UserMapper userMapper;

    @Override
    public User userLogin(User u) {
        return userMapper.userLogin(u);
    }

    @Override
    public List<User> getUsers() {
        return userMapper.getUsers();
    }

    @Override
    public int getUserCount() {
        return userMapper.getUserCount();
    }

    @Override
    public List<User> getUsersByPage(Map<String, Integer> cond) {

        return userMapper.getUsersByPage(cond);
    }
}
